import { createRouter, createWebHistory } from 'vue-router'
// import HomeView from '../views/HomeView.vue'
import FoundView from '../views/FoundView.vue'
import login from '../views/login.vue'

const routes = [
  {
    path: '/',
    name: 'home',
    component: FoundView
  },
  {
    path: '/found',
    name: 'found',
    component: () => import('../views/FoundView.vue')
  },
  {
    path: '/lost',
    name: 'lost',
    component: () => import('../views/LostView.vue')
  },
  {
    path: '/foundinfo/:objectId',
    name: 'foundinfo',
    component: () => import('../views/FoundInfoView.vue')
  },
  {
    path: '/lostinfo/:objectId',
    name: 'lostinfo',
    component: () => import('../views/LostInfoView.vue')
  },
  {
    path: '/AddInfo',
    name: 'Addinfo',
    component: () => import('../views/AddInfo.vue')
  },
  {
    path: '/AddLost',
    name: 'AddLost',
    component: () => import('../views/AddLost.vue')
  },
  {
    path: '/login',
    name: 'login',
    component: () => import('../views/login.vue')
  }
]

const router = createRouter({
  history: createWebHistory(process.env.BASE_URL),
  routes
})


export default router
